#include <paragraph.h>

#include "test.h"

#define Hand "\xe2\x98\x9d"
#define Black "\xf0\x9f\x8f\xbf"
#define Boy "\xf0\x9f\x91\xa6"
#define Man "\xf0\x9f\x91\xa8"
#define NoHair "\xf0\x9f\xa6\xb2"
#define ZWJ "\xe2\x80\x8d"
#define ShakeHand "\xf0\x9f\xa4\x9d"
#define Brother "\xf0\x9f\x91\xac"
#define ArabicHello "\xd9\x85\xd8\xb1\xd8\xad\xd8\xa8\xd8\xa7"
#define ArabicWorld "\xd8\xa7\xd9\x84\xd8\xb9\xd8\xa7\xd9\x84\xd9\x85"
#define ChineseHelloWorld "\xe4\xbd\xa0\xe5\xa5\xbd\xe4\xb8\x96\xe7\x95\x8c"
#define KeyConnector "\xef\xb8\x8f"
#define Key "\xe2\x83\xa3"
#define SnowMan "\xe2\x9b\x84"

class Test1 : public Test {
public:
    Test1()
    {
        p.SetText(Hand Black Hand " "
                  Man Black ZWJ NoHair " "
                  Boy Black " "
                  Man ZWJ Man ZWJ Boy " "
                  Brother " "
                  "Hello World, "
                  "Hello " ArabicHello " " ArabicWorld "."
                  ChineseHelloWorld ", "
                  "2" KeyConnector Key ", "
                  SnowMan ". "
                  ArabicHello " " ArabicWorld " Hello World");
    }

    void Draw(SkCanvas &canvas) override
    {
        Test::Draw(canvas);
        p.Paint(canvas);
    }

private:
    Paragraph p;
};

int main()
{
    Test1 test1;
    test1.Run();
    return 0;
}
